Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add meta text to DataView #2348

Merged
merged 3 commits into from
Sep 19, 2024
Merged

Add meta text to DataView #2348

merged 3 commits into from
Sep 19, 2024

Conversation

jordankoschei-okta
Copy link
Contributor

Screenshot 2024-09-10 at 10 41 18 PM Screenshot 2024-09-10 at 10 41 59 PM Screenshot 2024-09-10 at 10 42 13 PM

@jordankoschei-okta jordankoschei-okta requested a review from a team as a code owner September 11, 2024 02:42
Comment on lines +281 to +283
const additionalActions = useMemo(() => {
return (
(metaText ||
Copy link
Contributor

@KevinGhadyani-Okta KevinGhadyani-Okta Sep 18, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can make this an implicit return right?

But even then, there's a lot going on in here.

Is there a reason this isn't just another component?

React v19 would make this separate useMemo hook, but we don't need to do it here. It's only boolean checks.

This just seems like an unnecessary optimization by moving the boolean render of these action buttons up here rather than down in the return where we'd expect to see it.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like the idea of making this another component, but I don't have time to tackle that right now. Would you be comfortable with us shipping as-is and then doing a fast-follow PR to break this out into a new component?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes because it's more of a code styling thing. It doesn't affect consumers.

@oktapp-aperture-okta oktapp-aperture-okta bot merged commit 809f546 into main Sep 19, 2024
3 checks passed
@oktapp-aperture-okta oktapp-aperture-okta bot deleted the jk-table-meta branch September 19, 2024 19:32
jordankoschei-okta added a commit that referenced this pull request Sep 19, 2024
OKTA-807412 feat: add metaText to DataView
fix: remove unnecessary CSS empty check
Merge branch 'main' into jk-table-meta
oktapp-aperture-okta bot pushed a commit that referenced this pull request Sep 23, 2024
DES-6504 Add meta text to DataView (#2348)

OKTA-807412 feat: add metaText to DataView
fix: remove unnecessary CSS empty check
Merge branch 'main' into jk-table-meta
feat: add onPaginationChange hook
Merge branch '1.23' into jk-expose-pagination-change-on-dataview
fix: update tests to work in Bacon
fix: update tests to work in Bacon
fix: update tests to work in Bacon
oktapp-aperture-okta bot pushed a commit that referenced this pull request Sep 26, 2024
DES-6516 build: bump versions for 1.23.0
docs: update CHANGELOG for 1.23.0
Add meta text to DataView (#2348)

OKTA-807412 feat: add metaText to DataView
fix: remove unnecessary CSS empty check
Merge branch 'main' into jk-table-meta
fix(odyssey-react-mui): remove reference to babel-loader package
Add onPaginationChange hook to DataView (#2365)

DES-6504 Add meta text to DataView (#2348)

OKTA-807412 feat: add metaText to DataView
fix: remove unnecessary CSS empty check
Merge branch 'main' into jk-table-meta
feat: add onPaginationChange hook
Merge branch '1.23' into jk-expose-pagination-change-on-dataview
fix: update tests to work in Bacon
fix: update tests to work in Bacon
fix: update tests to work in Bacon
fix(odyssey-storybook): trigger test run
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants